home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Cream of the Crop 22
/
Cream of the Crop 22.iso
/
program
/
eflibpt4.zip
/
DEMO
/
MATH
/
MATHCPLX.PAS
next >
Wrap
Pascal/Delphi Source File
|
1996-07-21
|
767b
|
28 lines
{ Borland Pascal Extended Function Library - EFLIB (C) Johan Larsson, 1996
Demonstration; complex math
EFLIB IS PROTECTED BY THE COPYRIGHT LAW AND MAY NOT BE COPIED, SOLD OR
MANIPULATED. FOR MORE INFORMATION, SEE PROGRAM MANUAL! THIS DEMONSTRAT-
ION PROGRAM MAY FREELY BE USED AND DISTRIBUTED. }
uses EFLIBMTH, EFLIBSCR;
var N1, N2, N3 : ComplexObjectType;
{ EFLIBs complex numbers are handled in OOP }
begin
N1.Initialize (12.12, -4);
N2.Initialize (9, 3);
N3.Initialize (6, -2);
N1.Add (N2);
N1.Divide (N3);
Screen.Write ('The resulting complex number is ');
N1.Write (@Screen);
Screen.WriteLn ('.');
N3.Intercept; N2.Intercept; N1.Intercept;
end.